﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<ThanhCongJSC.Helper.PaginatedList<ThanhCongJSC.Models.Content>>" %>
<%@ Import Namespace="System.Globalization"%>
<%@ Import Namespace="ThanhCongJSC.Helper"%>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Thanh Cong JSC - Du An
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <h1 class="componentheading" style="margin-left:10px;margin-top:10px;"><b>Dự án</b></h1>
    <table border="0" cellpadding="0" cellspacing="0">
      <% foreach (var item in Model)
        { %>
        <tr>
            <td style="width: 220px">
		        <div class="portfolio_item" style="float:left;">
	                <a href='<%= Url.Action("Index", new { queryString = item.ContentCode }) %>' id="link_portfolio1" title="">
	        	        <img class="" src="<%= Url.Content(Constant.PathImageDuAn + item.ContentImage ?? string.Empty) %>" width="210px" height="112px" alt="">
	                </a>
	            </div>
	        </td>
	        <td style="width: 300px">
	            <div class="portfolio_Decrs">
	                <b><a style="color:Red" class="title" href='<%= Url.Action("Index", new { queryString = item.ContentCode }) %>'><%= item.ContentTitle %></a></b>
	                <p>Giá tiền : <%=  item.ProjectCost.ToString("##,#", new CultureInfo("vi-Vn"))%> VND</p>
	                <p>Ngày Khởi công :  <%= item.ProjectStartDate.ToString("dd/MM/yyyy", new CultureInfo("vi-Vn"))%> </p>
	            </div>
	        </td>
	    </tr>
	    <tr>
	        <td colspan="2">
                <img src="<%= Application["Root"]%>/Content/images/hinhphanchia.jpg" alt="" width="580px"/>
                <br />
                <br />
	         </td>
        </tr>
     <%} %>
     </table>
     
    <div style="text-align:right;color:#2222FF">
        <b>Trang : </b> 
        <% 
            for (int j = Model.PageIndex - 3; j < Model.PageIndex + 6; j++)
                if (j > 0 && j <= Model.TotalPages)
                {
                    if (j != Model.PageIndex + 1)
                        Response.Write(Html.ActionLink(j.ToString(), "Index", new
                        {
                            queryString = Constant.StringDanhSach + "-" + ViewData["QueryString"] + "-page" + (j).ToString()
                        }));
                    else
                        Response.Write(j.ToString());

                    if (j < Model.TotalPages)
                        Response.Write("&nbsp;|&nbsp;");
                }
        %>
    </div>
</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="CssJsRef" runat="server">
</asp:Content>
